#!/usr/bin/env python
# -*- coding: UTF-8 -*-
"""
@Project ：turbo 
@File    ：handler.py
@Author  ：赵加响
@Date    ：2023/4/23 14:41 
@Desc    ：
"""
from apps.accounts.models import SystemSettings


def get_system_setting(code):
    try:
        setting = SystemSettings.objects.get(code__exact=code, is_active=True)
        return setting.value.strip() if setting else ''
    except SystemSettings.DoesNotExist:
        return ''
